package web

import (
	"MoSkeleton/bootstrap"
	"MoSkeleton/framework"
	"context"
)

type WebApplication struct {
}

func (w *WebApplication) Run(args ...interface{}) {
	notifyChain := args[0].(chan int)
	bootstrap.DoSysInit()
	framework.ConfigContainerInst.GinConfig.StartServer(notifyChain)
}

func (w *WebApplication) Shutdown(ctx context.Context) {
	framework.ConfigContainerInst.GinConfig.Shutdown(ctx)
}
